# $Id: PKGBUILD 84277 2013-02-15 13:56:44Z dreisner $
# Maintainer: Dave Reisner <d@falconindy.com>

pkgname=jmeter
pkgver=2.9
pkgrel=2
arch=('any')
pkgdesc="A Java desktop application designed to load test functional behavior and measure performance"
url="http://jakarta.apache.org/jmeter/"
license=("apache")
depends=("java-environment")
options=('!strip')
source=("http://apache.ziply.com/jmeter/binaries/apache-$pkgname-$pkgver.tgz"{,.asc})
md5sums=('e3554185a6a256dfc503e64255dfa3e7'
         '72859d41fbaafaf70cf467f80fa406e2')

package() {
  install -dm755 "$pkgdir/opt/jmeter" "$pkgdir/usr/bin"

  cp -a "apache-$pkgname-$pkgver"/* "$pkgdir/opt/jmeter"
  ln -s /opt/jmeter/bin/jmeter "$pkgdir/usr/bin/jmeter"
  sed -i '/^java/s|`dirname "$0"`|/opt/jmeter/bin|' "$pkgdir/opt/jmeter/bin/jmeter"
}

# vim:set ts=2 sw=2 et:

